﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Admin.IService;
using Microsoft.AspNetCore.Mvc;

namespace Admin.Web.Controllers.Router
{
    /// <summary>
    /// 角色管理
    /// </summary>
    public class SysRoleController : BaseController
    {
        private ISysRoleService _sysRoleService;
        public SysRoleController(ISysRoleService sysRoleService)
        {
            _sysRoleService = sysRoleService;
        }
        public IActionResult Index()
        {
            return View();
        }
        public IActionResult Insert()
        {
            return View();
        }
        public async Task<IActionResult> Modify(int id)
        {
            var role = await _sysRoleService.Get(id);
            return View(role);
        }

        public IActionResult AuthUser(string roleId)
        {
            ViewBag.RoleId = roleId;
            return View();
        }

        public IActionResult SelectUser(string roleId)
        {
            ViewBag.RoleId = roleId;
            return View();
        }
    }
}